﻿using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using HZ.MBSM.DBUtility;
public partial class Deparment_Worker_Meeting_show : System.Web.UI.Page
{
    string strD_MeetingID;
    protected void Page_Load(object sender, EventArgs e)
    {
        System.Collections.Generic.List<HZ.MBSM.DAL.AccountType> _AccountType = new System.Collections.Generic.List<HZ.MBSM.DAL.AccountType>();
        _AccountType.Add(HZ.MBSM.DAL.AccountType.enumDeparment);
        if (HZ.MBSM.BLL.Login.CheckAssert(_AccountType))
        {
            strD_MeetingID = SysFun.PasswordDecrypt(Request.QueryString["D_MeetingID"].Trim());
            if (!IsPostBack)
            {
                ListInfor(strD_MeetingID);
            }
        }
    }



    private void ListInfor(string strD_MeetingID)
    {
        string sql = "select D_MeetingID,convert(varchar(100),AddDate,23) as AddDate ,Title,uploadFile,uploadFilePath, Content from D_Meeting where D_MeetingID=" + strD_MeetingID;
        Db db = new Db();
        DataTable dt = db.DataTable(sql);
        if (dt.Rows.Count > 0)
        {
            txtTitle.Text = dt.Rows[0]["title"].ToString();
            txtContent.Text = dt.Rows[0]["content"].ToString();
            if (dt.Rows[0]["uploadfile"].ToString().Trim() != "")
            {
                txtfj.Text = "<a target='_blank' href='" + dt.Rows[0]["uploadfilepath"].ToString() + "'><b>" + dt.Rows[0]["uploadfile"].ToString() + "</b></a>";
            }
            else
            {
                txtfj.Text = "<b>无附件</b>";
            }
          
        }
    }
}
